package com.sunjy.common.domain;

public enum HeaderEnum {
    /**
     * 系统级错误
     */
    SUC_MSG("200", ""),// 不可更改
    DUBBLE_MSG("0000","重复操作(操作成功)"),// 不可更改
    SYS_MSG("0001", "系统错误"),// 不可更改
    PARAM_MSG("0002", "参数错误"),
    DAO_MSG("0003", "数据异常"),
    SERVICE_MSG("0004", "服务异常"),
    WEB_MSG("0005", "网络异常,请重试"),
    WEB_REPEAT_SUBMIT("0006", "重复提交"),
    INVALID_REQUEST("0007", "非法请求"),
    NET_NOT_STABLE("0008", "网络不稳定，请稍后再试"),
    SIGN_ERROR("0009","签名错误！"),
    APPID_ERROR("0010" ,"应用的唯一标识错误"),
    DATE_ERROR("0011" ,"日期转换错误"),
    RESOLVER_FILE("0012" ,"解析文件错误"),
    /**
     * redis 相关的
     */
    REDIS_DELETE_KEY_ERROER("2010" ,"redis delete key error"),
    REDIS_KEY_NOT_EXIST("2012" ,"redis的key不存在"),
    REDIS_ERROR("2013" ,"redis异常"),
    PAYMENT_APPLY_KEY_ERROR("2014" ,"申报单处有效并且于锁定状态"),
    RESSSION_LOCK("2015" ,"请稍后重试"),
    /**
     * 用户相关
     */
    INVALID_SESSION("1001", "你已经退出登录!"), // 不可更改
    INVALID_USER_PASSWORD("1002","用户名或密码错误!"),//不可更改
    USER_NOT_EXIST("1003","用户名不存在!"),
    USER_IS_LOGIN("1004" ,"当前用户已经登录"),
    USER_SECOND_LOGIN("1005" ,"用户多地同时登录"),
    USER_AGE_INVALLID("1006","参保人年龄不符，已超上限"),


    /**
     * 文件上传相关
     */
    FILE_INPUSTREAM_IO_EXCEPTION("2001","上传失败！"),
    /**
     * 文件上传相关
     */
    FILE_EXPORTPDF_IO_EXCEPTION("2002","文件下载异常！"),

    /**
     * 异步下载相关
     */
    CREATE_DOWNLOAD_TASK_ERROR("2003","创建下载任务失败"),

    CREATE_DOWNLOAD_TASK_SUCCESS("2004","创建下载任务成功"),

    /**
     *
     */
    INVOKE_EXCEPTION("3001"," 调用错误"),

    RESOURCES_ARE_OCCUPIED("4001","资源被占用"),
	
	HYSTRIX_ERROR("5001","被限流");

    private String code;

    private String msg;


    HeaderEnum(String code, String msg) {
        this.code = code;
        this.msg = msg;
    }

    public String getCode() {
        return code;
    }

    public void setCode(String code) {
        this.code = code;
    }

    public String getMsg() {
        return msg;
    }

    public void setMsg(String msg) {
        this.msg = msg;
    }

}
